cmake_minimum_required(VERSION 2.6)

PROJECT(crop)
FIND_PACKAGE(ITK)
IF(ITK_FOUND)
INCLUDE(${ITK_USE_FILE})
ELSE(ITK_FOUND)
MESSAGE(FATAL_ERROR
"ITK not found. Please set ITK_DIR.")
ENDIF(ITK_FOUND)
MESSAGE (${ITK_USE_FILE})
MESSAGE (${ITK_INCLUDE_DIRS})
set(PROJECTNAME "crop")
ADD_EXECUTABLE(${PROJECTNAME} crop.cpp)
TARGET_LINK_LIBRARIES(${PROJECTNAME} ${ITK_LIBRARIES} )
ADD_CUSTOM_COMMAND(TARGET ${PROJECTNAME} POST_BUILD COMMAND copy \"$(TargetPath)\" \"../bin/exec\")



